<%@ Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false" CodeFile="NewUser.aspx.vb" Inherits="GTSWeb_Admin_NewUser" title="GTS Frieght Management System"  MaintainScrollPositionOnPostback="true" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder" Runat="Server">
    <asp:CreateUserWizard ID="CreateUserWizard1" runat="server" BackColor="#F7F6F3" BorderColor="#E6E2D8"
        BorderStyle="Solid" BorderWidth="1px" FinishDestinationPageUrl="~/Login.aspx"
        Font-Names="Verdana" Font-Size="0.8em" Height="103px" LoginCreatedUser="False"
        Width="375px">
        <WizardSteps>
            <asp:WizardStep ID="UserProfile" runat="server" Title="User Profile">
                <table border="0" style="font-size: 100%; width: 375px; font-family: Verdana; height: 103px">
                    <tr>
                        <td align="right" style="width: 162px; height: 26px">
                            <asp:Label ID="Label1" runat="server" Font-Names="Verdana" Font-Size="X-Small" Text="First Name"
                                Width="81px"></asp:Label>
                        </td>
                        <td style="height: 26px">
                            <asp:TextBox ID="txtFirstName" runat="server" Font-Names="Verdana" Font-Size="X-Small"></asp:TextBox>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtFirstName"
                                ErrorMessage="User Name is required." ToolTip="User Name is required." ValidationGroup="CreateUserWizard1">*</asp:RequiredFieldValidator>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" style="width: 162px; height: 26px">
                            <asp:Label ID="Label2" runat="server" Font-Names="Verdana" Font-Size="X-Small" Text="Last Name"
                                Width="81px"></asp:Label>
                        </td>
                        <td style="height: 26px">
                            <asp:TextBox ID="txtLastName" runat="server" Font-Names="Verdana" Font-Size="X-Small"></asp:TextBox>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txtLastName"
                                ErrorMessage="Last Name is required." ToolTip="User Name is required." ValidationGroup="CreateUserWizard1">*</asp:RequiredFieldValidator>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" style="width: 162px; height: 26px">
                            <asp:Label ID="lblRole" runat="server" Font-Names="Verdana" Font-Size="X-Small" Text="Role"
                                Width="76px"></asp:Label>
                        </td>
                        <td style="height: 26px">
                            <asp:DropDownList ID="ddlRole" runat="server" DataSourceID="ObjectDataSource3" Font-Names="Verdana"
                                Font-Size="X-Small" Width="154px">
                                <asp:ListItem Value="Manager"></asp:ListItem>
                                <asp:ListItem Value="User"></asp:ListItem>
                            </asp:DropDownList>
                            &nbsp;&nbsp;
    <asp:ObjectDataSource ID="ObjectDataSource2" runat="server" OldValuesParameterFormatString="original_{0}"
        SelectMethod="getAllClients" TypeName="GTSSystem.BLL.Client" InsertMethod="CreateClient" UpdateMethod="UpdateClient">
        <InsertParameters>
            <asp:Parameter Name="ClientName" Type="String" />
            <asp:Parameter Name="StatusId" Type="Int32" />
            <asp:Parameter Name="ContractStartDate" Type="DateTime" />
            <asp:Parameter Name="ContractEndDate" Type="DateTime" />
            <asp:Parameter Name="ContactName" Type="String" />
            <asp:Parameter Name="Phone" Type="String" />
            <asp:Parameter Name="Fax" Type="String" />
            <asp:Parameter Name="Email" Type="String" />
            <asp:Parameter Name="StreetAddress" Type="String" />
            <asp:Parameter Name="City" Type="String" />
            <asp:Parameter Name="ProvinceState" Type="String" />
            <asp:Parameter Name="Country" Type="String" />
            <asp:Parameter Name="PostalCode" Type="String" />
        </InsertParameters>
        <UpdateParameters>
            <asp:Parameter Name="ClientId" Type="Int32" />
            <asp:Parameter Name="ContactInfoId" Type="Int32" />
            <asp:Parameter Name="LocationId" Type="Int32" />
            <asp:Parameter Name="ClientName" Type="String" />
            <asp:Parameter Name="StatusId" Type="Int32" />
            <asp:Parameter Name="ContractStartDate" Type="DateTime" />
            <asp:Parameter Name="ContractEndDate" Type="DateTime" />
            <asp:Parameter Name="ContactName" Type="String" />
            <asp:Parameter Name="Phone" Type="String" />
            <asp:Parameter Name="Fax" Type="String" />
            <asp:Parameter Name="Email" Type="String" />
            <asp:Parameter Name="StreetAddress" Type="String" />
            <asp:Parameter Name="City" Type="String" />
            <asp:Parameter Name="ProvinceState" Type="String" />
            <asp:Parameter Name="Country" Type="String" />
            <asp:Parameter Name="PostalCode" Type="String" />
        </UpdateParameters>
    </asp:ObjectDataSource>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" style="width: 162px; height: 26px">
                            Client</td>
                        <td style="height: 26px">
                            <asp:DropDownList ID="ddlClient" runat="server" AutoPostBack="True" DataSourceID="ObjectDataSource2"
                                DataTextField="ClientName" DataValueField="ClientID" Font-Names="Verdana" Font-Size="X-Small"
                                Width="152px">
                            </asp:DropDownList>
    <asp:ObjectDataSource ID="ObjectDataSource1" runat="server"
        OldValuesParameterFormatString="original_{0}" SelectMethod="getClientBranch"
        TypeName="GTSSystem.BLL.ClientBranch">
        <SelectParameters>
            <asp:ControlParameter ControlID="ddlClient" Name="ClientId" PropertyName="SelectedValue"
                Type="Int32" />
        </SelectParameters>
    </asp:ObjectDataSource>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" style="width: 162px; height: 26px">
                            <asp:Label ID="Label3" runat="server" Font-Names="Verdana" Font-Size="X-Small" Text="Branch"
                                Width="76px"></asp:Label>
                        </td>
                        <td style="height: 26px">
                            <asp:DropDownList ID="ddlBranch" runat="server" AutoPostBack="True" DataSourceID="ObjectDataSource1"
                                DataTextField="BranchName" DataValueField="ClientBranchID" Font-Names="Verdana"
                                Font-Size="X-Small" Width="152px">
                            </asp:DropDownList>
                            &nbsp;&nbsp;
    <asp:ObjectDataSource ID="ObjectDataSource3" runat="server" OldValuesParameterFormatString="original_{0}"
        SelectMethod="getAllRoles" TypeName="GTSSystem.BLL.User"></asp:ObjectDataSource>
                        </td>
                    </tr>
                </table>
            </asp:WizardStep>
            <asp:CreateUserWizardStep ID="AboutUser" runat="server" Title="About the User">
                <CustomNavigationTemplate>
                    <table border="0" cellspacing="5" style="width: 100%; height: 100%">
                        <tr align="right">
                            <td align="right" colspan="0">
                                <asp:Button ID="StepNextButton" runat="server" BackColor="#FFFBFF" BorderColor="#CCCCCC"
                                    BorderStyle="Solid" BorderWidth="1px" CommandName="MoveNext" Font-Names="Verdana"
                                    ForeColor="#284775" Text="Create User" ValidationGroup="CreateUserWizard1" />
                            </td>
                        </tr>
                    </table>
                </CustomNavigationTemplate>
            </asp:CreateUserWizardStep>
            <asp:CompleteWizardStep ID="Complete" runat="server">
                <ContentTemplate>
                    <table border="0" style="font-size: 100%; width: 375px; font-family: Verdana; height: 103px">
                        <tr>
                            <td align="center" colspan="2" style="font-weight: bold; color: white; background-color: #5d7b9d">
                                Complete</td>
                        </tr>
                        <tr>
                            <td>
                                Your account has been successfully created.</td>
                        </tr>
                        <tr>
                            <td align="right" colspan="2">
                                <asp:Button ID="ContinueButton" runat="server" BackColor="#FFFBFF" BorderColor="#CCCCCC"
                                    BorderStyle="Solid" BorderWidth="1px" CausesValidation="False" CommandName="Continue"
                                    Font-Names="Verdana" ForeColor="#284775" OnClick="ContinueButton_Click1" Text="Continue"
                                    ValidationGroup="CreateUserWizard1" />
                            </td>
                        </tr>
                    </table>
                </ContentTemplate>
            </asp:CompleteWizardStep>
        </WizardSteps>
        <SideBarStyle BackColor="#5D7B9D" BorderWidth="0px" Font-Size="0.9em" VerticalAlign="Top" />
        <TitleTextStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
        <SideBarButtonStyle BorderWidth="0px" Font-Names="Verdana" ForeColor="White" />
        <NavigationButtonStyle BackColor="#FFFBFF" BorderColor="#CCCCCC" BorderStyle="Solid"
            BorderWidth="1px" Font-Names="Verdana" ForeColor="#284775" />
        <HeaderStyle BackColor="#5D7B9D" BorderStyle="Solid" Font-Bold="True" Font-Size="0.9em"
            ForeColor="White" HorizontalAlign="Center" />
        <CreateUserButtonStyle BackColor="#FFFBFF" BorderColor="#CCCCCC" BorderStyle="Solid"
            BorderWidth="1px" Font-Names="Verdana" ForeColor="#284775" />
        <ContinueButtonStyle BackColor="#FFFBFF" BorderColor="#CCCCCC" BorderStyle="Solid"
            BorderWidth="1px" Font-Names="Verdana" ForeColor="#284775" />
        <StepStyle BorderWidth="0px" />
        <HeaderTemplate>
            <span style="font-size: 14pt">New User Registration </span>
        </HeaderTemplate>
    </asp:CreateUserWizard>
    &nbsp;&nbsp;
</asp:Content>

